package responsex

type Response struct {
	Code int         `json:"code"`
	Msg  string      `json:"msg"`
	Data interface{} `json:"data"`
}

func SuccessResponse(data interface{}, msg string) Response {

	return Response{Code: 0, Msg: msg, Data: data}
}

func ErrorResponse(code int, msg string) Response {

	return Response{Code: code, Msg: msg}
}
